import random
import time

class Node:
    def __int__(self):
        #每隔10000秒就需要重新校准一次
        self.time_threshold = 10000
        pass

    def run(self):
        '''
        不同的结点有不同的run函数
        '''
        pass

    def check(self, last_calibration_time = None):
        '''
        check函数主要用来检测当前这一结点是否过时
        '''
        if time.time() - last_calibration_time > self.time_threshold:
            return 0
        else:
            return 1
        #assert last_calibration_time != None

    def system_drift(self, new_para_set, old_para_set):
        nonsense = [new_para_set, old_para_set]
        return False
